package com.app.yc.ifapp.entity;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * 作者：TanTun
 * 时间：2017/3/17
 * 邮箱：32965926@qq.com
 * 描述：红外设备实体类
 */

public class IrDevice implements Parcelable {
    String brand_Id;
    String device_Type;
    String device_Brand;
    String device_Model;
    List<IrData> ir_Datas;

    public String getBrand_Id() {
        return brand_Id;
    }

    public void setBrand_Id(String brand_Id) {
        this.brand_Id = brand_Id;
    }

    public String getDevice_Type() {
        return device_Type;
    }

    public void setDevice_Type(String device_Type) {
        this.device_Type = device_Type;
    }

    public String getDevice_Brand() {
        return device_Brand;
    }

    public void setDevice_Brand(String device_Brand) {
        this.device_Brand = device_Brand;
    }

    public String getDevice_Model() {
        return device_Model;
    }

    public void setDevice_Model(String device_Model) {
        this.device_Model = device_Model;
    }

    public List<IrData> getIr_Datas() {
        return ir_Datas;
    }

    public void setIr_Datas(List<IrData> ir_Datas) {
        this.ir_Datas = ir_Datas;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.brand_Id);
        dest.writeString(this.device_Type);
        dest.writeString(this.device_Brand);
        dest.writeString(this.device_Model);
        dest.writeTypedList(this.ir_Datas);
    }

    public IrDevice() {
    }

    protected IrDevice(Parcel in) {
        this.brand_Id = in.readString();
        this.device_Type = in.readString();
        this.device_Brand = in.readString();
        this.device_Model = in.readString();
        this.ir_Datas = in.createTypedArrayList(IrData.CREATOR);
    }

    public static final Parcelable.Creator<IrDevice> CREATOR = new Parcelable.Creator<IrDevice>() {
        @Override
        public IrDevice createFromParcel(Parcel source) {
            return new IrDevice(source);
        }

        @Override
        public IrDevice[] newArray(int size) {
            return new IrDevice[size];
        }
    };
}
